package com.boot.rocketmq.listener;

import org.apache.rocketmq.spring.annotation.RocketMQMessageListener;
import org.apache.rocketmq.spring.core.RocketMQListener;
import org.springframework.stereotype.Component;

@Component
@RocketMQMessageListener(topic = "topic_test", consumerGroup = "consumer-group")
public class OneWayMessageListener implements RocketMQListener<String> {

    @Override
    public void onMessage(String s) {
        System.out.println("接收MQ单向消息：" + s);
    }
}
